import MyDialogManager from "../../lib/MyDialogManager";
import Sdk from "../../lib/Sdk";
import {ui} from "../../ui/layaMaxUI";
export default class QuitDialog extends ui.QuitDialogUI{
    onEnable(){
        this.quitBtn.once(Laya.Event.CLICK,this,this.quitClick);
        this.okBtn.once(Laya.Event.CLICK,this,this.close);
        Sdk.getIns().showBanner();
    }

    onDisable(){
        Sdk.getIns().hideBanner();
    }

    private quitClick(){
        MyDialogManager.getIns().sceneOpen("FailDialog.scene");
        this.close();
    }
}